- Description:
This key toggles whether CloudCannon should treat an entry in the
valuesarray as the default option for your Object or Array input.Setting this key to
truewill mark this entry as the default option for your Object or Array input. If multiple entries in thevaluesarray are set totrue, CloudCannon will use the first entry. If CloudCannon cannot determine the type of an entry within thevaluesarray based on theid_keyor matching inputs acrossvalues[*].valueobjects, it will fall back to the default entry.- Appears in:
- Type:
boolean- Default value:
false- Examples:
In this example, we want the entry labelled
Employeeto be our default option for populating inputs configured with thestaffStructure.Copied to clipboard_structures: staff: style: modal values: - label: Employee default: true value: name: job_description: profile_picture: - label: Manager value: name: job_description: profile_picture: url:{ "_structures": { "staff": { "style": "modal", "values": [ { "label": "Employee", "default": true, "value": { "name": null, "job_description": null, "profile_picture": null } }, { "label": "Manager", "value": { "name": null, "job_description": null, "profile_picture": null, "url": null } } ] } } }